//
//  OfficalCell.m
//  GolfFriend
//
//  Created by vescky on 14-2-3.
//  Copyright (c) 2014年 vescky.org. All rights reserved.
//

#import "OfficalCell.h"
#import "DateUtility.h"

@interface OfficalCell ()

@end

@implementation OfficalCell


- (void)setCellDataInfo:(NSDictionary*)cDict {
    if (!cDict || [cDict count] < 1) {
        return;
    }
    NSDate *_date = getDateFromString(@"yyyy-MM-dd HH:mm:ss", [cDict objectForKey:@"time"]);
    NSString *dateString = getStringFromDate(@"yyyy-MM-dd", _date);
    NSString *timeString = getStringFromDate(@"HH:mm", _date);
    
    NSString *titleString = [cDict objectForKey:@"title"];
    
    [labelDate setText:dateString];
    [labelTime setText:timeString];
    [labelTitle setText:titleString];
    NSLog(@"------- %d ---------",self.tag%2);
    if (self.tag%2 ) {
        //奇数
        [imgViewBg setBackgroundColor:[UIColor colorWithRed:234.0/255 green:234.0/255 blue:234.0/255 alpha:1.0]];
        
    }
    else {
        [imgViewBg setBackgroundColor:[UIColor whiteColor]];
    }
    
//    NSString *timeStr = 
}


@end
